/**
 * RemoveTopicAction.java 1.0 2007-5-25 上午01:23:40,创建 by yangfan
 */


package org.in4j.bbs.action.topic;

import org.in4j.bbs.action.AbstractAction;
import org.in4j.bbs.service.TopicService;

/**
 *
 * @author yangfan
 * @version 1.0 2007-5-25 上午01:23:40,创建
 */
@SuppressWarnings("serial")
public class RemoveTopicAction extends AbstractAction
{
	private int topicId;
	private TopicService topicService;

	@Override
	public String execute() throws Exception
	{
		if(getOnlineInfo().getUser().isGuest()) return ERROR;
		topicService.removeTopic(topicId);
		return SUCCESS;
	}

	public void setTopicId(int topicId)
	{
		this.topicId = topicId;
	}

	public void setTopicService(TopicService topicService)
	{
		this.topicService = topicService;
	}

}
